/*
 * XML Type:  BorrowerAddress
 * Namespace: http://ofx.net/types/2003/04
 * Java type: net.ofx.types.x2003.x04.BorrowerAddress
 *
 * Automatically generated - do not modify.
 */
package net.ofx.types.x2003.x04.impl;
/**
 * An XML BorrowerAddress(@http://ofx.net/types/2003/04).
 *
 * This is a complex type.
 */
public class BorrowerAddressImpl extends org.apache.xmlbeans.impl.values.XmlComplexContentImpl implements net.ofx.types.x2003.x04.BorrowerAddress
{
    
    public BorrowerAddressImpl(org.apache.xmlbeans.SchemaType sType)
    {
        super(sType);
    }
    
    private static final javax.xml.namespace.QName BORROWERNAME$0 = 
        new javax.xml.namespace.QName("", "BORROWERNAME");
    private static final javax.xml.namespace.QName ADDR1$2 = 
        new javax.xml.namespace.QName("", "ADDR1");
    private static final javax.xml.namespace.QName ADDR2$4 = 
        new javax.xml.namespace.QName("", "ADDR2");
    private static final javax.xml.namespace.QName ADDR3$6 = 
        new javax.xml.namespace.QName("", "ADDR3");
    private static final javax.xml.namespace.QName CITY$8 = 
        new javax.xml.namespace.QName("", "CITY");
    private static final javax.xml.namespace.QName STATE$10 = 
        new javax.xml.namespace.QName("", "STATE");
    private static final javax.xml.namespace.QName POSTALCODE$12 = 
        new javax.xml.namespace.QName("", "POSTALCODE");
    
    
    /**
     * Gets the "BORROWERNAME" element
     */
    public java.lang.String getBORROWERNAME()
    {
        synchronized (monitor())
        {
            check_orphaned();
            org.apache.xmlbeans.SimpleValue target = null;
            target = (org.apache.xmlbeans.SimpleValue)get_store().find_element_user(BORROWERNAME$0, 0);
            if (target == null)
            {
                return null;
            }
            return target.getStringValue();
        }
    }
    
    /**
     * Gets (as xml) the "BORROWERNAME" element
     */
    public net.ofx.types.x2003.x04.GenericNameType xgetBORROWERNAME()
    {
        synchronized (monitor())
        {
            check_orphaned();
            net.ofx.types.x2003.x04.GenericNameType target = null;
            target = (net.ofx.types.x2003.x04.GenericNameType)get_store().find_element_user(BORROWERNAME$0, 0);
            return target;
        }
    }
    
    /**
     * Sets the "BORROWERNAME" element
     */
    public void setBORROWERNAME(java.lang.String borrowername)
    {
        synchronized (monitor())
        {
            check_orphaned();
            org.apache.xmlbeans.SimpleValue target = null;
            target = (org.apache.xmlbeans.SimpleValue)get_store().find_element_user(BORROWERNAME$0, 0);
            if (target == null)
            {
                target = (org.apache.xmlbeans.SimpleValue)get_store().add_element_user(BORROWERNAME$0);
            }
            target.setStringValue(borrowername);
        }
    }
    
    /**
     * Sets (as xml) the "BORROWERNAME" element
     */
    public void xsetBORROWERNAME(net.ofx.types.x2003.x04.GenericNameType borrowername)
    {
        synchronized (monitor())
        {
            check_orphaned();
            net.ofx.types.x2003.x04.GenericNameType target = null;
            target = (net.ofx.types.x2003.x04.GenericNameType)get_store().find_element_user(BORROWERNAME$0, 0);
            if (target == null)
            {
                target = (net.ofx.types.x2003.x04.GenericNameType)get_store().add_element_user(BORROWERNAME$0);
            }
            target.set(borrowername);
        }
    }
    
    /**
     * Gets the "ADDR1" element
     */
    public java.lang.String getADDR1()
    {
        synchronized (monitor())
        {
            check_orphaned();
            org.apache.xmlbeans.SimpleValue target = null;
            target = (org.apache.xmlbeans.SimpleValue)get_store().find_element_user(ADDR1$2, 0);
            if (target == null)
            {
                return null;
            }
            return target.getStringValue();
        }
    }
    
    /**
     * Gets (as xml) the "ADDR1" element
     */
    public net.ofx.types.x2003.x04.AddressType xgetADDR1()
    {
        synchronized (monitor())
        {
            check_orphaned();
            net.ofx.types.x2003.x04.AddressType target = null;
            target = (net.ofx.types.x2003.x04.AddressType)get_store().find_element_user(ADDR1$2, 0);
            return target;
        }
    }
    
    /**
     * True if has "ADDR1" element
     */
    public boolean isSetADDR1()
    {
        synchronized (monitor())
        {
            check_orphaned();
            return get_store().count_elements(ADDR1$2) != 0;
        }
    }
    
    /**
     * Sets the "ADDR1" element
     */
    public void setADDR1(java.lang.String addr1)
    {
        synchronized (monitor())
        {
            check_orphaned();
            org.apache.xmlbeans.SimpleValue target = null;
            target = (org.apache.xmlbeans.SimpleValue)get_store().find_element_user(ADDR1$2, 0);
            if (target == null)
            {
                target = (org.apache.xmlbeans.SimpleValue)get_store().add_element_user(ADDR1$2);
            }
            target.setStringValue(addr1);
        }
    }
    
    /**
     * Sets (as xml) the "ADDR1" element
     */
    public void xsetADDR1(net.ofx.types.x2003.x04.AddressType addr1)
    {
        synchronized (monitor())
        {
            check_orphaned();
            net.ofx.types.x2003.x04.AddressType target = null;
            target = (net.ofx.types.x2003.x04.AddressType)get_store().find_element_user(ADDR1$2, 0);
            if (target == null)
            {
                target = (net.ofx.types.x2003.x04.AddressType)get_store().add_element_user(ADDR1$2);
            }
            target.set(addr1);
        }
    }
    
    /**
     * Unsets the "ADDR1" element
     */
    public void unsetADDR1()
    {
        synchronized (monitor())
        {
            check_orphaned();
            get_store().remove_element(ADDR1$2, 0);
        }
    }
    
    /**
     * Gets the "ADDR2" element
     */
    public java.lang.String getADDR2()
    {
        synchronized (monitor())
        {
            check_orphaned();
            org.apache.xmlbeans.SimpleValue target = null;
            target = (org.apache.xmlbeans.SimpleValue)get_store().find_element_user(ADDR2$4, 0);
            if (target == null)
            {
                return null;
            }
            return target.getStringValue();
        }
    }
    
    /**
     * Gets (as xml) the "ADDR2" element
     */
    public net.ofx.types.x2003.x04.AddressType xgetADDR2()
    {
        synchronized (monitor())
        {
            check_orphaned();
            net.ofx.types.x2003.x04.AddressType target = null;
            target = (net.ofx.types.x2003.x04.AddressType)get_store().find_element_user(ADDR2$4, 0);
            return target;
        }
    }
    
    /**
     * True if has "ADDR2" element
     */
    public boolean isSetADDR2()
    {
        synchronized (monitor())
        {
            check_orphaned();
            return get_store().count_elements(ADDR2$4) != 0;
        }
    }
    
    /**
     * Sets the "ADDR2" element
     */
    public void setADDR2(java.lang.String addr2)
    {
        synchronized (monitor())
        {
            check_orphaned();
            org.apache.xmlbeans.SimpleValue target = null;
            target = (org.apache.xmlbeans.SimpleValue)get_store().find_element_user(ADDR2$4, 0);
            if (target == null)
            {
                target = (org.apache.xmlbeans.SimpleValue)get_store().add_element_user(ADDR2$4);
            }
            target.setStringValue(addr2);
        }
    }
    
    /**
     * Sets (as xml) the "ADDR2" element
     */
    public void xsetADDR2(net.ofx.types.x2003.x04.AddressType addr2)
    {
        synchronized (monitor())
        {
            check_orphaned();
            net.ofx.types.x2003.x04.AddressType target = null;
            target = (net.ofx.types.x2003.x04.AddressType)get_store().find_element_user(ADDR2$4, 0);
            if (target == null)
            {
                target = (net.ofx.types.x2003.x04.AddressType)get_store().add_element_user(ADDR2$4);
            }
            target.set(addr2);
        }
    }
    
    /**
     * Unsets the "ADDR2" element
     */
    public void unsetADDR2()
    {
        synchronized (monitor())
        {
            check_orphaned();
            get_store().remove_element(ADDR2$4, 0);
        }
    }
    
    /**
     * Gets the "ADDR3" element
     */
    public java.lang.String getADDR3()
    {
        synchronized (monitor())
        {
            check_orphaned();
            org.apache.xmlbeans.SimpleValue target = null;
            target = (org.apache.xmlbeans.SimpleValue)get_store().find_element_user(ADDR3$6, 0);
            if (target == null)
            {
                return null;
            }
            return target.getStringValue();
        }
    }
    
    /**
     * Gets (as xml) the "ADDR3" element
     */
    public net.ofx.types.x2003.x04.AddressType xgetADDR3()
    {
        synchronized (monitor())
        {
            check_orphaned();
            net.ofx.types.x2003.x04.AddressType target = null;
            target = (net.ofx.types.x2003.x04.AddressType)get_store().find_element_user(ADDR3$6, 0);
            return target;
        }
    }
    
    /**
     * True if has "ADDR3" element
     */
    public boolean isSetADDR3()
    {
        synchronized (monitor())
        {
            check_orphaned();
            return get_store().count_elements(ADDR3$6) != 0;
        }
    }
    
    /**
     * Sets the "ADDR3" element
     */
    public void setADDR3(java.lang.String addr3)
    {
        synchronized (monitor())
        {
            check_orphaned();
            org.apache.xmlbeans.SimpleValue target = null;
            target = (org.apache.xmlbeans.SimpleValue)get_store().find_element_user(ADDR3$6, 0);
            if (target == null)
            {
                target = (org.apache.xmlbeans.SimpleValue)get_store().add_element_user(ADDR3$6);
            }
            target.setStringValue(addr3);
        }
    }
    
    /**
     * Sets (as xml) the "ADDR3" element
     */
    public void xsetADDR3(net.ofx.types.x2003.x04.AddressType addr3)
    {
        synchronized (monitor())
        {
            check_orphaned();
            net.ofx.types.x2003.x04.AddressType target = null;
            target = (net.ofx.types.x2003.x04.AddressType)get_store().find_element_user(ADDR3$6, 0);
            if (target == null)
            {
                target = (net.ofx.types.x2003.x04.AddressType)get_store().add_element_user(ADDR3$6);
            }
            target.set(addr3);
        }
    }
    
    /**
     * Unsets the "ADDR3" element
     */
    public void unsetADDR3()
    {
        synchronized (monitor())
        {
            check_orphaned();
            get_store().remove_element(ADDR3$6, 0);
        }
    }
    
    /**
     * Gets the "CITY" element
     */
    public java.lang.String getCITY()
    {
        synchronized (monitor())
        {
            check_orphaned();
            org.apache.xmlbeans.SimpleValue target = null;
            target = (org.apache.xmlbeans.SimpleValue)get_store().find_element_user(CITY$8, 0);
            if (target == null)
            {
                return null;
            }
            return target.getStringValue();
        }
    }
    
    /**
     * Gets (as xml) the "CITY" element
     */
    public net.ofx.types.x2003.x04.AddressType xgetCITY()
    {
        synchronized (monitor())
        {
            check_orphaned();
            net.ofx.types.x2003.x04.AddressType target = null;
            target = (net.ofx.types.x2003.x04.AddressType)get_store().find_element_user(CITY$8, 0);
            return target;
        }
    }
    
    /**
     * True if has "CITY" element
     */
    public boolean isSetCITY()
    {
        synchronized (monitor())
        {
            check_orphaned();
            return get_store().count_elements(CITY$8) != 0;
        }
    }
    
    /**
     * Sets the "CITY" element
     */
    public void setCITY(java.lang.String city)
    {
        synchronized (monitor())
        {
            check_orphaned();
            org.apache.xmlbeans.SimpleValue target = null;
            target = (org.apache.xmlbeans.SimpleValue)get_store().find_element_user(CITY$8, 0);
            if (target == null)
            {
                target = (org.apache.xmlbeans.SimpleValue)get_store().add_element_user(CITY$8);
            }
            target.setStringValue(city);
        }
    }
    
    /**
     * Sets (as xml) the "CITY" element
     */
    public void xsetCITY(net.ofx.types.x2003.x04.AddressType city)
    {
        synchronized (monitor())
        {
            check_orphaned();
            net.ofx.types.x2003.x04.AddressType target = null;
            target = (net.ofx.types.x2003.x04.AddressType)get_store().find_element_user(CITY$8, 0);
            if (target == null)
            {
                target = (net.ofx.types.x2003.x04.AddressType)get_store().add_element_user(CITY$8);
            }
            target.set(city);
        }
    }
    
    /**
     * Unsets the "CITY" element
     */
    public void unsetCITY()
    {
        synchronized (monitor())
        {
            check_orphaned();
            get_store().remove_element(CITY$8, 0);
        }
    }
    
    /**
     * Gets the "STATE" element
     */
    public java.lang.String getSTATE()
    {
        synchronized (monitor())
        {
            check_orphaned();
            org.apache.xmlbeans.SimpleValue target = null;
            target = (org.apache.xmlbeans.SimpleValue)get_store().find_element_user(STATE$10, 0);
            if (target == null)
            {
                return null;
            }
            return target.getStringValue();
        }
    }
    
    /**
     * Gets (as xml) the "STATE" element
     */
    public net.ofx.types.x2003.x04.StateType xgetSTATE()
    {
        synchronized (monitor())
        {
            check_orphaned();
            net.ofx.types.x2003.x04.StateType target = null;
            target = (net.ofx.types.x2003.x04.StateType)get_store().find_element_user(STATE$10, 0);
            return target;
        }
    }
    
    /**
     * True if has "STATE" element
     */
    public boolean isSetSTATE()
    {
        synchronized (monitor())
        {
            check_orphaned();
            return get_store().count_elements(STATE$10) != 0;
        }
    }
    
    /**
     * Sets the "STATE" element
     */
    public void setSTATE(java.lang.String state)
    {
        synchronized (monitor())
        {
            check_orphaned();
            org.apache.xmlbeans.SimpleValue target = null;
            target = (org.apache.xmlbeans.SimpleValue)get_store().find_element_user(STATE$10, 0);
            if (target == null)
            {
                target = (org.apache.xmlbeans.SimpleValue)get_store().add_element_user(STATE$10);
            }
            target.setStringValue(state);
        }
    }
    
    /**
     * Sets (as xml) the "STATE" element
     */
    public void xsetSTATE(net.ofx.types.x2003.x04.StateType state)
    {
        synchronized (monitor())
        {
            check_orphaned();
            net.ofx.types.x2003.x04.StateType target = null;
            target = (net.ofx.types.x2003.x04.StateType)get_store().find_element_user(STATE$10, 0);
            if (target == null)
            {
                target = (net.ofx.types.x2003.x04.StateType)get_store().add_element_user(STATE$10);
            }
            target.set(state);
        }
    }
    
    /**
     * Unsets the "STATE" element
     */
    public void unsetSTATE()
    {
        synchronized (monitor())
        {
            check_orphaned();
            get_store().remove_element(STATE$10, 0);
        }
    }
    
    /**
     * Gets the "POSTALCODE" element
     */
    public java.lang.String getPOSTALCODE()
    {
        synchronized (monitor())
        {
            check_orphaned();
            org.apache.xmlbeans.SimpleValue target = null;
            target = (org.apache.xmlbeans.SimpleValue)get_store().find_element_user(POSTALCODE$12, 0);
            if (target == null)
            {
                return null;
            }
            return target.getStringValue();
        }
    }
    
    /**
     * Gets (as xml) the "POSTALCODE" element
     */
    public net.ofx.types.x2003.x04.ZipType xgetPOSTALCODE()
    {
        synchronized (monitor())
        {
            check_orphaned();
            net.ofx.types.x2003.x04.ZipType target = null;
            target = (net.ofx.types.x2003.x04.ZipType)get_store().find_element_user(POSTALCODE$12, 0);
            return target;
        }
    }
    
    /**
     * True if has "POSTALCODE" element
     */
    public boolean isSetPOSTALCODE()
    {
        synchronized (monitor())
        {
            check_orphaned();
            return get_store().count_elements(POSTALCODE$12) != 0;
        }
    }
    
    /**
     * Sets the "POSTALCODE" element
     */
    public void setPOSTALCODE(java.lang.String postalcode)
    {
        synchronized (monitor())
        {
            check_orphaned();
            org.apache.xmlbeans.SimpleValue target = null;
            target = (org.apache.xmlbeans.SimpleValue)get_store().find_element_user(POSTALCODE$12, 0);
            if (target == null)
            {
                target = (org.apache.xmlbeans.SimpleValue)get_store().add_element_user(POSTALCODE$12);
            }
            target.setStringValue(postalcode);
        }
    }
    
    /**
     * Sets (as xml) the "POSTALCODE" element
     */
    public void xsetPOSTALCODE(net.ofx.types.x2003.x04.ZipType postalcode)
    {
        synchronized (monitor())
        {
            check_orphaned();
            net.ofx.types.x2003.x04.ZipType target = null;
            target = (net.ofx.types.x2003.x04.ZipType)get_store().find_element_user(POSTALCODE$12, 0);
            if (target == null)
            {
                target = (net.ofx.types.x2003.x04.ZipType)get_store().add_element_user(POSTALCODE$12);
            }
            target.set(postalcode);
        }
    }
    
    /**
     * Unsets the "POSTALCODE" element
     */
    public void unsetPOSTALCODE()
    {
        synchronized (monitor())
        {
            check_orphaned();
            get_store().remove_element(POSTALCODE$12, 0);
        }
    }
}
